export default [
  {
    path: 'manage',
    name: 'Manage',
    meta: { title: '生产管理', icon: 'micon2.png' },
    hidden: false,
    // redirect: '/plant/plan',
    code: '8001|8002|8003|8004|8005|8006|8007|8008|8009|8010|8011',
    children: [
      {
        path: 'plan',
        name: 'Manage-Plan-List',
        hidden: false,
        code: '8002|8003|8004',
        meta: { title: '种植方案', keepAlive: true },
        redirect: '/manage/plan/list',
        children: [
          {
            path: 'list',
            name: 'Manage-Plan-List',
            hidden: true,
            meta: { title: '种植方案', keepAlive: true },
            component: () => import('@/view/produceManage/plan/list.vue'),
          },
          {
            path: 'add',
            name: 'Manage-Plan-Add',
            hidden: true,
            meta: { title: '创建方案', icon: 'Calendar' },
            component: () => import('@/view/produceManage/plan/add.vue'),
          },
          {
            path: 'create', // 自动创建方案（演示临时增加）
            name: 'Manage-Plan-Create', 
            hidden: true,
            meta: { title: '创建方案', icon: 'Calendar' },
            component: () => import('@/view/produceManage/plan/create.vue'),
          },
          {
            path: 'eidt',
            name: 'Manage-Plan-Edit',
            hidden: true,
            meta: { title: '编辑种植计划', icon: 'Calendar' },
            component: () => import('@/view/produceManage/plan/add.vue'),
          },
          {
            path: 'detail',
            name: 'Manage-Plan-Detail',
            hidden: true,
            meta: { title: '种植计划详情', icon: 'Calendar' },
            component: () => import('@/view/produceManage/plan/detail.vue'),
          },
          {
            path: 'detail/land',
            name: 'Manage-Plan-Detail-land',
            hidden: true,
            meta: { title: '地块详情', icon: 'Calendar' },
            component: () => import('@/view/produceManage/plan/landDetail.vue'),
          }
        ]
      },
      {
        path: 'task',
        name: 'Manage-Task-List',
        hidden: false,
        code: '8006|8007',
        meta: { title: '农事任务', keepAlive: true },
        // component: () => import('@/view/plant/task/index.vue'),
        redirect: '/manage/task/list',
        children: [
          {
            path: 'list',
            name: 'Manage-Task-List',
            hidden: true,
            meta: { title: '农事任务', icon: 'Calendar', keepAlive: true },
            component: () => import('@/view/produceManage/task/list.vue'),
          },
          {
            path: 'detail',
            name: 'Manage-Task-Detail',
            hidden: true,
            meta: { title: ' 任务详情', icon: 'Calendar' },
            component: () => import('@/view/produceManage/task/detail.vue'),
          }
        ]
      },
      {
        path: 'record',
        name: 'Manage-Record-Index',
        hidden: false,
        code: '8009',
        meta: { title: '农事记录', keepAlive: true },
        redirect: '/manage/record/index',
        children: [
          {
            path: 'index',
            name: 'Manage-Record-Index',
            hidden: true,
            meta: { title: '农事记录', icon: 'Calendar' },
            component: () => import('@/view/produceManage/record/index.vue'),
          }
        ]
      },
      {
        path: 'crop',
        name: 'Manage-Crop-Index',
        hidden: false,
        code: '8011',
        meta: { title: '作物长势', keepAlive: true },
        redirect: '/manage/crop/index',
        children: [
          {
            path: 'index',
            name: 'Manage-Crop-Index',
            hidden: true,
            meta: { title: '作物长势', icon: 'Calendar' },
            component: () => import('@/view/produceManage/crop/index.vue'),
          }
        ]
      }
    ]
  }
]
